/*
 * @author Javier A. Ramírez M.
 * jaramirez85@yahoo.es
 */

package com.jav;

import com.sun.lwuit.Dialog;
import com.sun.lwuit.Image;
import com.sun.lwuit.Label;
import com.sun.lwuit.layouts.BorderLayout;
import com.sun.lwuit.util.Resources;

public class VentanaEspera extends Dialog {

    public VentanaEspera(String titulo) {
        super(titulo);
        setLayout(new BorderLayout());
        Image images = null;        
        try {
            Resources res = Datos.getInstance().getRes();
            images =  res.getAnimation("wait");
        } catch (Exception ex) {
            ex.printStackTrace();
        }
            Image load = images;
            load.scaled(70, 70);
            Label ani = new Label(load);
            ani.setAlignment(Label.CENTER);
            ani.getStyle().setBgTransparency(0);
            registerAnimated(ani);
            getStyle().setBgColor(0xFFFFFF);
            addComponent(BorderLayout.CENTER, ani);    
        
    }   
}
